<%@ page contentType="text/html;charset=UTF-8"%>
<!DOCTYPE html "-//W3C//DTD XHTML 1.0 Strict//EN" 
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <title>Google Maps JavaScript API Example</title>
    <script src="http://ditu.google.cn/maps?file=api&v=2&key=ABQIAAAAKx4k5etAEsgs4MnNrjUH_RT2yXp_ZAY8_ufC3CFXhHIE1NvwkxRST6IJK5ZgdOUAlC5MDDpxcDumwA&sensor=true_or_false"
        type="text/javascript">
	</script>
    <script type="text/javascript">

    function initialize() {
      if (GBrowserIsCompatible()) {
        var map = new GMap2(document.getElementById("map_canvas"));
        var center = new GLatLng(39.917,116.397);
        map.setCenter(center, 14);
 
        var marker = new GMarker(center, {draggable: true});
 
        GEvent.addListener(marker, "dragstart", function() {
          map.closeInfoWindow();
        });
 
        GEvent.addListener(marker, "dragend", function() {
          marker.openInfoWindowHtml("已经进行了拖动，正在反弹...");
        });
 
        map.addOverlay(marker);
 
      }
    }

    </script>
  </head>
  <body onload="initialize()" onunload="GUnload()">
    <div id="map_canvas" style="width: 500px; height: 300px"></div>
    <div>
    <a href="/google/maps/test">google Maps Api test</a></br>
    <a href="/google/maps/bounds">google Maps Api getBounds()</a></br>
    <a href="/google/maps/markerDrag">google Maps Api markerDrag</a></br>
    </div>
  </body>
</html>